#ifndef DATA_PLAYER_H
#define DATA_PLAYER_H

#include <string>
#include "Data/Objects/PlayerType.h"

namespace data {

	struct Player {
	public:
		Player(
			PlayerType type,
			std::string name,
			std::string creatureId ) :
			m_type( type ),
			m_name( name ),
			m_creatureId( creatureId )
		{}

		Player( const Player& player ) :
			m_type( player.m_type ),
			m_name( player.m_name ),
			m_creatureId( player.m_creatureId )
		{}

		inline const std::string GetName() const { return m_name; }
		inline void SetName( std::string name ) { m_name = name; }

		inline const PlayerType GetType() const { return m_type; }
		inline void SetType( PlayerType type ) { m_type = type; }

		inline const std::string GetCreatureId() const { return m_creatureId; }
		inline void SetCreatureId( std::string creatureId ) { m_creatureId = creatureId; }

	private:
		PlayerType m_type;
		std::string m_name;
		std::string m_creatureId;
	};

	inline bool operator == ( const Player& a, const Player& b ) {
		if( a.GetName() != b.GetName() ) return false;
		if( a.GetType() != b.GetType() ) return false;
		if( a.GetCreatureId() != b.GetCreatureId() ) return false;
		return true;
	}

	inline bool operator != ( const Player& a, const Player& b ) {
		return !( a == b );
	}
}
#endif
